package com.trade.module.database.meta;

import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;

/**
 * @Desc: 表字段元数据
 * @Version: v1.0 2017/12/6 16:09
 * @Author: zfb
 * @JDK Version: 1.8.0_51
 */
@Getter
@NoArgsConstructor
@AllArgsConstructor
public class ColumnMetaData {
    //列名
    private String name;
    //列值的类型
    private String type;
    //列备注
    private String remark;
    //字段长度
    private Integer length;
    //小数点位数
    private Integer digitsLength;

    public ColumnMetaData(String name, String type, String remark, Integer length) {
        this.name = name;
        this.type = type;
        this.remark = remark;
        this.length = length;
    }

    @Override
    public String toString() {
        return "ColumnMetaData{" +
                "name='" + name + '\'' +
                ", type='" + type + '\'' +
                ", remark='" + remark + '\'' +
                ", length=" + length +
                ", digitsLength=" + digitsLength +
                '}';
    }
}
